<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>
        div{
            border: 1px solid red;
            float: left;;
        }
        .test1{
            margin-top: 10px;
        }
        .test2{
            margin-top: 20px;
        }
        .test3{
            margin-top: 30px;
        }
    </style>
</head>
<body>
<div>
    <div class="test1">1</div>
    <div class="test2">1</div>
    <div class="test3">1</div>
    <div class="test4">1</div>
</div>
</body>
</html>